package com.mac.pojo;

import java.sql.Timestamp;

/**
 * 创建教育资源表 EducationalResources 实体类
 * 包含在线教育资源信息
 */
public class EducationalResources {

    // 资源唯一标识，自增主键
    private Integer resourceId;

    // 资源标题，不能为空
    private String title;

    // 资源类型，不能为空
    private String resourceType;

    // 资源链接，不能为空
    private String url;

    // 资源描述
    private String description;

    // 发布日期，默认为当前时间
    private Timestamp publishDate;

    public EducationalResources() {
    }

    public EducationalResources(Integer resourceId, String title, String resourceType, String url, String description, Timestamp publishDate) {
        this.resourceId = resourceId;
        this.title = title;
        this.resourceType = resourceType;
        this.url = url;
        this.description = description;
        this.publishDate = publishDate;
    }

    public Integer getResourceId() {
        return resourceId;
    }

    public void setResourceId(Integer resourceId) {
        this.resourceId = resourceId;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getResourceType() {
        return resourceType;
    }

    public void setResourceType(String resourceType) {
        this.resourceType = resourceType;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public Timestamp getPublishDate() {
        return publishDate;
    }

    public void setPublishDate(Timestamp publishDate) {
        this.publishDate = publishDate;
    }

    @Override
    public String toString() {
        return "EducationalResources{" +
                "resourceId=" + resourceId +
                ", title='" + title + '\'' +
                ", resourceType='" + resourceType + '\'' +
                ", url='" + url + '\'' +
                ", description='" + description + '\'' +
                ", publishDate=" + publishDate +
                '}';
    }
}
